SslClient

Instance of

Class

Inherits from

TcpClient

Description

SSL client provides secure socket (such as SSL or TLS) input and output operations.

Example

// HTTPS request
let tcpClientA = SslClient();
await tcpClientA.connect("www.example.com", 443);
await tcpClientA.send("GET / HTTP/1.1\r\nHost: www.example.com\r\n\r\n");
console.write((await tcpClientA.receive()).split("\r")[0]);
await tcpClientA.close();

Expected output

HTTP/1.1 200 OK

Members

  • constructor

Inherited members

Properties

  • classPrototype